Cleanup for r44700 -- work on a clone of $wgTitle instead of modifying the fragment...
authorBrion Vibber <brion@users.mediawiki.org>
Tue, 23 Dec 2008 17:58:22 +0000 (17:58 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Tue, 23 Dec 2008 17:58:22 +0000 (17:58 +0000)
includes/ImagePage.php

index 49e7f2d..e2a0b36 100644 (file)
@@ -965,13 +965,17 @@ class ImageHistoryList {
 class ImageHistoryPseudoPager extends ReverseChronologicalPager {
        function __construct( $imagePage ) {
                parent::__construct();
-               $this->mImagePage =& $imagePage;
-               $this->mTitle = $imagePage->getTitle();
+               $this->mImagePage = $imagePage;
+               $this->mTitle = clone( $imagePage->getTitle() );
                $this->mTitle->setFragment( '#filehistory' );
                $this->mImg = NULL;
                $this->mHist = array();
                $this->mRange = array( 0, 0 ); // display range
        }
+       
+       function getTitle() {
+               return $this->mTitle;
+       }
 
        function getQueryInfo() {
                return false;